<div class="col-lg-10">
	<?php $countCrumb = count($crumb); ?>
	<?php $i = 0; ?>
	<div class="row">
		<ol class="breadcrumb">
			<?php foreach($crumb as $key => $value) : ?>
				<?php $i++; ?>
				<?php if($i == $countCrumb) : ?>
					<li class="active"><?=$key?></li>
				<?php else : ?>
					<li><a href="<?=$value?>"><?=$key?></a></li>
				<?php endif ?>
			<?php  endforeach ?>
		</ol>
	</div>
	
	<?php if($this->session->flashdata('sess_Info') !== "") : ?>
		<h4><?php echo $this->session->flashdata('sess_Info')?></h4>
	<?php endif ?>
	<div class="row">
		<form class="form-horizontal" id="frm_add_person" method="post" enctype="multipart/form-data">
	        			<fieldset>
    						<legend>Add a person</legend>
							  <div class="form-group">
							    <label for="inputEmail2" class="col-lg-2 control-label">Name</label>
							    <div class="col-lg-10">
							      <input type="text" name="name" value="<?php echo set_value("name")?>" class="form-control" id="inputPassword2" placeholder="Enter name">
							      <span class="help-block"><?php echo form_error('name')?></span>
							    </div>
							  </div>
							  <div class="form-group">
							    <label for="inputPassword2" class="col-lg-2 control-label">Date of birth</label>
							    <div class="col-lg-4">
							      <input type="datetime" name="day_birth" value="<?php echo set_value("day_birth")?>" class="form-control" id="day_birth" placeholder="Date of birth">
							      <span class="help-block"><?php echo form_error('day_birth')?></span>
							    </div>
							    <label for="inputPassword2" class="col-lg-2 control-label">Date of death</label>
							    <div class="col-lg-4">
							      <input type="datetime" name="day_death" value="<?php echo set_value("day_death")?>" class="form-control" id="day_death" placeholder="Date of death">
							      <span class="help-block"><?php echo form_error('day_death')?></span>
							    </div>
							  </div>
							  <div class="form-group">
							    <label for="inputPassword2" class="col-lg-2 control-label">Country</label>
							    <div class="col-lg-4">
							      <select class="form-control" id="sl_country" name="sl_country" placeholder="Date of birth">
							      		<option value="">Select a country</option>
							      		<?php foreach($countries as $country) : ?>
							      			<option value="<?php echo $country['id']?>"><?php echo $country['country']?></option>
							      		<?php endforeach ?>
							      </select>
							      <span class="help-block"><?php echo form_error('sl_country')?></span> 
							    </div>
							    <label for="inputPassword2" class="col-lg-2 control-label">State</label>
							    <div class="col-lg-4">
							      <select class="form-control" name="sub_region" id="sub_region" placeholder="Date of birth">
							      		<option value="">Select a state</option>
							      </select> 
							    </div>
							  </div>
							  <div class="form-group">
								    <label for="inputEmail2" class="col-lg-2 control-label">Description</label>
								    <div class="col-lg-10">
								      <textarea row="3" name="desc" class="form-control"></textarea>
								    </div>
							  </div>
							  <div class="form-group">
								    <label for="inputPassword2" class="col-lg-2 control-label">Public</label>
								    <div class="col-lg-1">
								      <input type="radio" checked name="chk" value="1">
								    </div>
								    <label for="inputPassword2" class="col-lg-2 control-label">Private</label>
								    <div class="col-lg-1">
								      <input type="radio" name="chk" value="0">
								    </div> 
							  </div>
							  <div class="form-group">
							      <label for="exampleInputFile" class="col-lg-2 control-label">Photo cover</label>
							      <input type="file" name="photo_cover" id="exampleInputFile" class="col-lg-4 control-label">
							      <!--<p class="help-block">Example block-level help text here.</p>-->
							    </div>
							   <p class="col-lg-offset-1">
							   		<button type="button" class="btn btn-primary" onclick="$('#frm_add_person').submit()">Submit</button>
							   </p>
						</fieldset>
		</form>
	</div>
</div><!--End col 10-->
	        </div>
	    </div>

  	</div>

  	<link href="<?php echo base_url()?>public/datepicker/themes/smoothness/jquery-ui.css" rel="stylesheet">
  	<script type="text/javascript" src="<?php echo base_url()?>public/datepicker/js/jquery-ui-1.10.3.custom.js"></script>

  	<script>
	  $(function() {
	    $( "#day_birth" ).datepicker({
	    	dateFormat:"yy-mm-dd",
	    	changeMonth: true,
      		changeYear: true,
      		yearRange: "1920:2020"
	    });
	    $( "#day_death" ).datepicker({
	    	dateFormat:"yy-mm-dd",
	    	changeMonth: true,
      		changeYear: true,
      		yearRange: "1920:2020"
	    });
	  });
  </script>